<?php
/* 
 * akimimi front
 * 
 * modify password View
 * 
 * @author steve
 * 
 */
require_once '../app/views/BaseView.php';

class ModifyPasswordView extends BaseView {
	public function getPage(){
		$this->setPageTitle(constant("MODIFYPASSWORD"));
		$this->addJS('frontend.js',true);
		$this->addCSS('myaccountleftnav.css');
		$this->addCSS('myaccount.css');
		$header = '';
		$str_result = $header
                    . $this->getContent();
        return $this->getHtmlPage($str_result);
	}
	
	
	public function getContent(){
		$str_hidden = '<input type="hidden" id="errorOldPasswordEmpty" value="'.OLDPASSWORDEMPTY.'" /><input type="hidden" id="errorOldPasswordError" value="'.OLDPASSWORDERROR.'" />';
		$str_hidden .= '<input type="hidden" id="errorNewPasswordEmpty" value="'.NEWPASSWORDEMPTY.'" /><input type="hidden" id="errorPasswordError" value="'.PASSWORDERROR.'" />';
		$str_hidden .= '<input type="hidden" id="errorPasswordRight" value="'.PASSWORDRIGHT.'" /><input type="hidden" id="errorRepasswordEmpty" value="'.REPEATPASSWORDEMPTY.'" />';
		$str_hidden .= '<input type="hidden" id="errorRepasswordError" value="'.REPEATPASSWORDERROR.'" /><input type="hidden" id="errorRepasswordRight" value="'.REPEATPASSWORDRIGHT.'" />';
		
		$str_result = '<div id="navigation"><a href="/">'.WEBSITEINDEXPAGETXT.'</a><span>></span><a href="/userinfo/index">'.MYAKIMIMITXT.'</a><span>></span><a href="/userinfo/modifypassword">'.MODIFYPASSWORD.'</a></div>';
	    $str_result .= $str_hidden;
	    $str_result .= '<div id="mymimi_body">';
	    $str_result .= MyAccountLeftNav::getMyAccountLeftNav();
	    $str_result .= '<div id="mymimi_right"><div class="right_bj"></div><div id="password_list">';
	    $str_result .= '<div id="password_nav"><ul><li class="title_1">'.MODIFYPASSWORD.'</li></ul></div>';
	    $str_result .= '<div class="password_border"><div id="mima">';
	    $str_result .= '<form action="/o/modifypassword" method="post" id="modifyPasswordForm" onsubmit="javascript:return ModifyPassword.modifySubmit();">';
	    $str_result .= '<div class="body_left"><div class="left_row"><ul><li class="style_1">'.OLDPASSWORD.COLON.'</li>';
	    $str_result .= '<li class="style_2"><input type="password" id="oldPassword" name="oldPassword" onblur="javascript:ModifyPassword.validateOldPassword();"  class="input_modify_psw"/></li>';
        $str_result .= '<li class="style_3"><span id="errorOldPassword" class="error_font_color" ></span></li>';
	    $str_result .= '</ul></div>';
	    $str_result .= '<div class="left_row"><ul><li class="style_1">'.NEWPASSWORD.COLON.'</li>';
	    $str_result .= '<li class="style_2"><input type="password" id="newPassword" name="newPassword" onblur="javascript:ModifyPassword.validateNewPassword();"  class="input_modify_psw"/></li>';
        $str_result .= '<li class="style_3"><span id="errorNewpassword" class="error_font_color"  ></span></li></ul></div>';
	    $str_result .= '<div class="left_row"><ul><li class="style_1">'.REPEATPASSWORD.COLON.'</li>';
	    $str_result .= '<li class="style_2"><input type="password" id="repassword" name="repassword" onblur="javascript:ModifyPassword.validateRepassword();"  class="input_modify_psw"/></li>';
        $str_result .= '<li class="style_3"><span id="errorRepassword" class="error_font_color" ></span></li></ul></div>';
        $str_result .= '<div class="left_row_1"><input type="button" id="button"  value="'.SAVEBTN.'" class="button" onclick="javascript:ModifyPassword.modifySubmit();" /></div></div>';
	    $str_result .= '<div class="body_right"><img src="'.ConfigConstants::getTImagePath().'/mimi_010.jpg" alt="" /></div>';
	    $str_result .= '</form></div></div></div></div></div>';
	    
	    return $str_result;
	    
	}
}

?>
